Dependent Types with Subtyping and Late-Bound Overloading
نویسندگان
چکیده
We present a calculus with dependent types, subtyping and late-bound overloading. Besides its theoretical interest this work is motivated by several practical needs that range from the definition of logic encodings, to proof specialization and reuse, and to object-oriented extension of the SML module system. The theoretical study of this calculus is not straightforward. While confluence is relatively easy to prove, subject reduction is much harder. We were not able to add overloading to any existing system with dependent types and subtyping, and prove subject reduction. This is why we also define here as by-product a new subtyping system for dependent types that improves previous systems and enjoys several properties (notably the transitivity elimination property). The calculus with overloading is then obtained as a conservative extension of this new system. Another difficult point is strong normalization, which is a necessary condition to the decidability of subtyping and typing relations. The calculus with overloading is not strongly normalizing. However, we show that a reasonably useful fragment of the calculus enjoys this property, and that its strong normalization implies the decidability of its subtyping and typing relations. The article is divided into two parts: the first three sections provide a general overview of the systems and its motivations, and can be read separately; the remaining sections develop the formal study.
منابع مشابه
A semantics for λ { } str : a calculus with overloading and late - binding
Up to now there was no interpretation available for λ-calculi featuring overloading and late-binding, although these are two of the main principles of any object-oriented programming language. In this paper we provide a new semantics for a stratified version of Castagna’s λ{}, a λ-calculus combining overloading with late-binding. The model-construction is carried out in EETJ + (Tot) + (F-IN), a...
متن کاملOverloading, subtyping and late binding - functional foundation of object-oriented programming
متن کامل
Order-Sorted Inductive Types
System F ! is an extension of system F ! with subtyping and bounded quantiication. Order-sorted algebra is an extension of many-sorted algebra with overloading and subtyping. We combine both formalisms to obtain IF ! , a higher-order typed-calculus with subtyping, bounded quan-tiication and order-sorted inductive types, i.e. data types with built-in subtyping and overloading. Moreover we show t...
متن کاملObject-Oriented Verification Based on Record Subtyping in Higher-Order Logic
We show how extensible records with structural subtyping can be represented directly in Higher-Order Logic (HOL). Exploiting some speci c properties of HOL, this encoding turns out to be extremely simple. In particular, structural subtyping is subsumed by naive parametric polymorphism, while overridable generic functions may be based on overloading. Taking HOL plus extensible records as a start...
متن کاملPrincipal Type Schemes for Functional Programs with Overloading and Subtyping
We show how the Hindley/Milner polymorphic type system can be extended to incorporate overloading and subtyping. Our approach is to attach constraints to quantified types in order to restrict the allowed instantiations of type variables. We present an algorithm for inferring principal types and prove its soundness and completeness. We find that it is necessary in practice to simplify the inferr...
متن کاملذخیره در منابع من
با ذخیره ی این منبع در منابع من، دسترسی به آن را برای استفاده های بعدی آسان تر کنید
برای دانلود متن کامل این مقاله و بیش از 32 میلیون مقاله دیگر ابتدا ثبت نام کنید
ثبت ناماگر عضو سایت هستید لطفا وارد حساب کاربری خود شوید
ورودعنوان ژورنال:
- Inf. Comput.
دوره 168 شماره
صفحات -
تاریخ انتشار 2001